
/**
 * Printing formatted data
 * 
 * @author Amrita Mukherjee
 * @version 11/1/12
 */
public class PrintingFieldsofData
{
   public static void main(String[] args)
    {
        String item = "Carrot";
        int quantity = 5;
        double price = 0.23;
        
        System.out.printf("Item is = %s, quantity = %d, price = $%.2f\n", item, quantity, price);
    }

}
/* my tese session:
 * Item is = Carrot, quantity = 5, price = $0.23
 */